package android.itv.library;

import java.util.ArrayList;

import android.itv.model.Channel;

public class ConvertChannel
{
    public static ArrayList<Channel> getListChannel(ArrayList<android.itv.modesevice.Channel> list)
    {
	ArrayList<Channel> listChannel=new ArrayList<Channel>();
	Channel channel;
	android.itv.modesevice.Channel channelService;
	for(int i=0;i<list.size();i++)
	{
	    channel=new Channel();
	    channelService=list.get(i);
	    channel.setCategory(channelService.getProperty(0).toString());
	    channel.setDescriptions(channelService.getProperty(1).toString());
	    channel.setIdChannel(channelService.getProperty(2).toString());
	    channel.setLinkLogo(channelService.getProperty(3).toString());
	    channel.setLinktv(channelService.getProperty(4).toString());
	    channel.setName(channelService.getProperty(5).toString());
	    
	    listChannel.add(channel);  
	}
	return listChannel;
    }
}
